#ifndef EXPRESSION_COMMON_H
#define EXPRESSION_COMMON_H

#include "../types/wfnettypes.h"

#include <QVariant>
#include <coretypes.h>

#include <QtCore/QHash>

namespace wfnet
{

class SystemVariable
{
public:
    SystemVariable();
    SystemVariable(const core::TypeName& type, const QVariant& value,
        bool containsVariable, const VariableName& varName);

public:
    core::TypeName m_type;
    QVariant m_value;
    bool m_containsVariable;
    VariableName m_variableName;
};

typedef QHash<VariableName, SystemVariable> SystemVariables;
typedef QHash<VariableName, core::TypeName> UserVariables;

enum ExpressionType
{
    NONE = 0x0, // ASSERT
    SIMPLE_VAL_ONLY = 0x1,
    SIMPLE_VAR_ONLY = 0x2,
    SIMPLE_MUL_VAR = 0x4,
    COMPLEX_VAR_VAL = 0x8,
    COMPLEX_VAR_VAR = 0x16,
    SIMPLE_UNBOUND_VAR_ONLY = 0x32
};

} // namespace wfnet

#endif
